<?php if (!defined('THINK_PATH')) exit();?><!DOCTYPE HTML>
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no">
    <meta content="yes" name="apple-mobile-web-app-capable" />
    <meta content="email=no" name="format-detection"/>
    <meta content="telephone=no" name="format-detection" />
    <title><?php echo ($drug['product_name']); ?>_大众品药</title>
    <link href="/Public/css/layout.css" type="text/css" rel="stylesheet" >
    <script src="/Public/js/jquery-1.10.1.min.js"></script>
    <script src="/Public/js/TouchSlide.1.1.js" type="text/javascript"></script>
</head>
<body>
<div class="head">
    <div class="head-cont"><a href="javascript:history.back();"><i class="icon-iconfont-fanhui"></i></a>
        <a href="/collection/<?php echo ($drug['objectId']); ?>"><i class="icon-iconfont-star"></i></a>
        <span class="head-tit"><?php echo ($drug['product_name']); ?></span>
    </div>
</div>
<div class="page">
    <div class="h45"></div>
    <!--banner start-->
    <div class="banner">
        <div id="slideBox" class="slideBox">
            <div class="bd">
                <ul>
                    <?php foreach($drug['images']['banner'] as $k=>$v){ ?>
                    <li> <a class="pic" href="#"><img src="<?php echo ($v); ?>" /></a> </li>
                    <?php } ?>
                </ul>
            </div>
            <div class="hd">
                <ul>
                </ul>
            </div>
        </div>
        <script type="text/javascript">
            TouchSlide({
                slideCell:"#slideBox",
                titCell:".hd ul",
                mainCell:".bd ul",
                effect:"leftLoop",
                autoPage:true,
                autoPlay:true
            });
        </script>
    </div>
    <!-- banner end-->
    <div class="proshow">
        <div class="proshow-tit"><?php echo ($drug['product_name']); ?><span class="proshow-tit-right">
            <?php if($drug['yibao_drug']){ ?>
            <img src="/Public/images/bao.jpg" class="proshow-bao">
            <?php } ?>
            <?php if($drug['OTC']){ ?>
            <img src="/Public/images/otc.jpg" class="proshow-otc"></span>
            <?php } ?>
            <?php if($drug['base_drug']){ ?>
            <img src="/Public/images/base.jpg" class="proshow-otc"></span>
            <?php } ?>
            <?php if($drug['product_cate'] == '中药'){ ?>
            <img src="/Public/images/zhongyao.jpg" class="proshow-otc"></span>
            <?php } ?>
            <?php if($drug['product_cate'] == '化学药品'){ ?>
            <img src="/Public/images/xiyao.jpg" class="proshow-otc"></span>
            <?php } ?>
            <span class="proshow-deso"><?php echo ($drug['instructions']['生产企业']); ?><br/>
     <?php echo ($drug['major_cure']); ?></span> <span class="proshow-price"><span class="proshow-lsprice">零售价</span> ￥<?php echo ($drug['price']['online']); ?>~￥<?php echo ($drug['price']['market']); ?></span> </div>
    </div>
    <div class="proshow2">
        <div class="proshow-pf">
            <span class="proshow-pf-l">总评分<span class="proshow-pf-cs"><?php echo ($drug['score']); ?></span></span>
            <?php for($i = 0; $i < intval($drug['score']); $i++){ echo '<i class="icon-iconfont-star1"></i>'; } ?>
            <?php for($j = 0; $j < 5 - intval($drug['score']); $j++){ echo '<i class="icon-iconfont-star2"></i>'; } ?>
        </div>
        <div class="proshow-pf-con">
            <span class="proshow-pf-con-li">
                <span class="proshow-pf-lj">
                    <span class="proshow-pf-yuan"></span>
                </span>
                <span class="proshow-pf-con-r">治疗效果（<?php echo ($drug['total_score_detail']['cure']); ?>）</span>
            </span>
            <span class="proshow-pf-con-li">
                <span class="proshow-pf-lj">
                    <span class="proshow-pf-yuan"></span>
                </span>
                <span class="proshow-pf-con-r">性价比（<?php echo ($drug['total_score_detail']['price']); ?>）</span>
            </span>
            <span class="proshow-pf-con-li">
                <span class="proshow-pf-lj">
                    <span class="proshow-pf-yuan"></span>
                </span>
                <span class="proshow-pf-con-r">外包装（<?php echo ($drug['total_score_detail']['buy']); ?>）</span>
            </span>
            <span class="proshow-pf-con-li">
                <span class="proshow-pf-lj">
                    <span class="proshow-pf-yuan"></span>
                </span>
                <span class="proshow-pf-con-r">购买便利度（<?php echo ($drug['total_score_detail']['package']); ?>）</span>
            </span><span class="proshow-pf-con-li">
                <span class="proshow-pf-lj">
                    <span class="proshow-pf-yuan"></span>
                </span>
                <span class="proshow-pf-con-r">购买便利度（<?php echo ($drug['total_score_detail']['use']); ?>）</span>
            </span><span class="proshow-pf-con-li">
                <span class="proshow-pf-lj">
                    <span class="proshow-pf-yuan"></span>
                </span>
                <span class="proshow-pf-con-r">购买便利度（<?php echo ($drug['total_score_detail']['side_effect']); ?>）</span>
            </span>
        </div>
    </div>
    <div class="proshow2"><span class="proshow-sms"><i class="icon-iconfont-gengduo"></i>说明书</span></div>
    <div class="proshow3"><span class="proshow-hot-pl"><a href="javascript:alert('请下载app');"><span>查看<?php echo ($comment_count); ?>条评论</span></a>热门评论</span>
        <ul class="proshow-hot-pl-ul">
            <?php foreach($comment as $k=>$v){ ?>
            <li>
                <span class="proshow-hot-pl-top">
                    <span class="proshow-hot-pl-time"><?php echo ($v['created_at']); ?></span>
                    <?php if(!empty($v['userInfo']['avatar'])){ ?>
                        <?php if(strpos($v['userInfo']['avatar'],':')){ ?>
                            <img src="<?php echo ($v['userInfo']['avatar']); ?>" class="proshow-hot-pl-img">
                        <?php }else{ ?>
                            <img src="http://7xlaxq.com1.z0.glb.clouddn.com/<?php echo ($v['userInfo']['avatar']); ?>" class="proshow-hot-pl-img">
                    <?php }}else{ ?>
                    <img src="http://7xlaxq.com1.z0.glb.clouddn.com/AppIcon512.png" class="proshow-hot-pl-img">
                    <?php } ?>
                    <span class="proshow-hot-pl-tit"><?php echo ($v['userInfo']['nickname']); ?></span>
                    <span class="proshow-hot-pl-star">
                        <?php for($i = 0; $i < intval($v['scoreInfo']); $i++){ echo '<i class="icon-iconfont-star1"></i>'; } ?>
                        <?php for($j = 0; $j < 5 - intval($v['scoreInfo']); $j++){ echo '<i class="icon-iconfont-star2"></i>'; } ?>
                    </span>
                </span>
                <span class="proshow-hot-pl-mid"><?php echo ($v['content']); ?></span>
                <span class="proshow-hot-pl-btm">
                    <span class="proshow-hot-pl-zan">
                        <span class="proshow-hot-pl-con"><i class="icon-iconfont-zan"></i>(<?php echo rand(1,20);?>)</span>
                    </span>
                    <span class="proshow-hot-pl-pl">
                        <span class="proshow-hot-pl-con"><i class="icon-iconfont-pinglun"></i>(<?php echo ($v['replay_count']); ?>)</span>
                    </span>
                </span>
            </li>
            <?php } ?>
        </ul>
    </div>
    <div class="h45"></div>
</div>
<div class="proshow-foot">
    <span class="proshow-foot-sub">
        <span class="proshow-foot-sx"></span>
        <span class="proshow-foot-sub-c">
            <a href="javascript:alert('请下载app');"><i class="icon-iconfont-dibiao"></i>附近药店</a>
        </span>
    </span>
    <span class="proshow-foot-sub">
        <span class="proshow-foot-sub-c">
            <a href="/comment/<?php echo ($drug['objectId']); ?>"><i class="icon-iconfont-bianjixiaoxi"></i>我要点评</a>
        </span>
    </span>
</div>
</body>
</html>